home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MACD 5
/
MACD 5.bin
/
internet
/
yam_i_dodatki
/
yam-list-1.0.lha
/
unsubscribe.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1996-12-31
|
1KB
|
30 lines
/*
** $VER: Unsubscribe.rexx 1.0 (12.30.96)
**
** Written by Peter Greci <midgard@nycmetro.com>
**
** It scans the incoming folder for messages with the subject
** "Subscribe" and adds the sender to the list.
**/
OPTIONS RESULTS
ADDRESS YAM
SetFolder 0 /* go to Incoming folder */
GetFolderInfo MAX; entries = RESULT /* get number of mail */
DO i=0 TO entries-1 /* scan all mail */
SetMail i /* set topical mail */
GetMailInfo SUBJECT /* ask for subject */
IF RESULT = 'unsubscribe' THEN DO /* criteria accomplished */
GetMailInfo FROM /* ask for sender and */
ret=RESULT /* save as variable ret */
mailarchive 3
mailwrite /* Bids Goodbye to a */
writemailto ret /* subscriber */
writesubject 'GoodBye'
writeletter 'listserv:bye'
writequeue
mailsendall
END
END
exit